package org.csu.controller;

import org.csu.pojo.UserQuery;
import org.csu.service.UserManageService;
import org.springframework.stereotype.Controller;

import javax.annotation.Resource;

@Controller(value="userManageController")
public class UserManageController {
    @Resource(name="userManageService")
    private UserManageService userManageService;
    public String getUserList(UserQuery query, Integer pageNum){
        return userManageService.getUserList(query, pageNum);
    }
    public Boolean enableUser(Integer userId){
        return userManageService.enableUser(userId);
    }
    public Boolean  disableUser(Integer userId){
        return userManageService.disableUser(userId);
    }
    public Boolean  resetPassword(Integer userId){
        return userManageService.resetPassword(userId);
    }
    public Boolean  changeRole(Integer userId, String role){
        return userManageService.changeRole(userId, role);
    }
}
